package com.wen.service;

import com.wen.manager.MemcacheCacheManager;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.cache.Cache;
import org.springframework.cache.annotation.CachePut;
import org.springframework.stereotype.Service;

import java.io.Serializable;

/**
 * Created by teddy on 2017/3/30.
 */
@Service
public class TestService {
    @Autowired
    private MemcacheCacheManager cacheManager;

    public void test() {
        Cache a = cacheManager.getCache("a");
        a.put("asdf", "asdf");

        a = cacheManager.getCache("a");
        System.out.println(a.get("asdf"));
    }
}
